#include <iostream>
using namespace std;
int main()
{
   int num{1};
   cout << "num is " << num << endl;
   // 1、指针
   int *p = &num;
   *p = 2;
   cout << "num is " << num << endl;
   // 2、引用
   int &ref = num;
   ref = 3;
   cout << "num is " << num << endl;
   return 0;
}
